package com.ews.onlineexchange.model;

import java.util.ArrayList;
import java.util.List;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.Lob;
import javax.persistence.OneToMany;
import javax.validation.constraints.NotNull;

import org.hibernate.validator.constraints.Email;

@Entity
public class FeedBack extends DataEntity {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	private String       title;                           //反馈意见标题(或针对哪一部分)
	
	private String       content;                         //反馈内容
	
	private List<Image>  images = new ArrayList<Image>();					      //相关截图
	
	private String       contactorPhoneNumber ;			  //联系手机号
	
	private String       email;							  //邮箱
	
	private String       hasHandled ;				  	  //0 未处理 ，1 处理
	
	@NotNull
	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}
	@Lob
	@NotNull
	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}
	@OneToMany(cascade=CascadeType.ALL)
	public List<Image> getImages() {
		return images;
	}

	public void setImages(List<Image> images) {
		this.images = images;
	}
		
	public String getContactorPhoneNumber() {
		return contactorPhoneNumber;
	}

	public void setContactorPhoneNumber(String contactorPhoneNumber) {
		this.contactorPhoneNumber = contactorPhoneNumber;
	}

	@NotNull
	@Email
	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public String getHasHandled() {
		return hasHandled;
	}

	public void setHasHandled(String hasHandled) {
		this.hasHandled = hasHandled;
	}
	
	
	
}
